<template>
  <div class="customer-log-wrap">
    <div class="title">客户日志</div>
    <el-scrollbar class="scrollbar">
      <div class="log-title success mt-10">签单后</div>
      <el-select placeholder="请选择合同" clearable>
        <el-option v-for="item in [{ label: 1, value: 1 }]" :key="item.value" :label="item.label" :value="item.value" />
      </el-select>
      <div class="log-item" v-for="item in 3" :key="item">
        <div class="time success">2024-04-22 08:00</div>
        <div class="content">
          <div class="text">HT3308885324-中科商标注册合同</div>
          <div class="text">AJ55081864-<span class="success">已递交</span></div>
          <div class="text">操作人：邓梦楠</div>
        </div>
      </div>

      <div class="log-title signed mt-10">合同签订</div>
      <el-select placeholder="请选择合同" clearable>
        <el-option v-for="item in [{ label: 1, value: 1 }]" :key="item.value" :label="item.label" :value="item.value" />
      </el-select>
      <div class="log-item" v-for="item in 3" :key="item">
        <div class="time signed">2024-04-22 08:00</div>
        <div class="content">
          <div class="text">HT3308885324-中科商标注册合同</div>
          <div class="text">合同审核-<span class="success">审核通过</span></div>
          <div class="text">操作人：邓梦楠</div>
          <el-button type="primary" size="small" plain>提醒他</el-button>
        </div>
      </div>

      <div class="log-title resource-collection mt-10">资源领取</div>
      <div class="log-item" v-for="item in 3" :key="item">
        <div class="time">2024-04-22 08:00</div>
        <div class="content">
          <div class="text">资源领取-挽救库</div>
          <div class="text">操作人：邓梦楠</div>
        </div>
      </div>

      <!-- <el-empty description="暂无客户日志数据"></el-empty> -->
    </el-scrollbar>
  </div>
</template>

<script lang="ts" setup></script>

<style lang="scss" scoped>
.customer-log-wrap {
  display: flex;
  flex-direction: column;
  height: 100%;

  .el-select {
    margin: 5px 0;
  }

  .scrollbar {
    flex: 1;
    padding-top: 10px;
  }

  .log-title {
    line-height: 24px;
    border-radius: 4px;
    background: rgba(31, 97, 243, 0.1);
    color: #3370ff;
    padding: 0 10px;

    &.signed {
      color: #ff803d;
      background: rgba(255, 128, 61, 0.1);
    }
    &.success {
      color: #30cb82;
      background: rgba(48, 203, 130, 0.1);
    }
  }

  .log-item {
    .time {
      line-height: 22px;
      color: #909399;
      display: flex;
      align-items: center;

      &::before {
        content: "";
        display: inline-block;
        width: 9px;
        height: 9px;
        background: #3370ff;
        border-radius: 50%;
        margin-right: 4px;
        margin-top: -2px;
      }

      &.signed {
        &::before {
          background: #ff803d;
        }
      }
      &.success {
        &::before {
          background: #30cb82;
        }
      }
    }

    .content {
      border-left: 1px solid #d9d9d9;
      margin-left: 4px;
      line-height: 22px;
      margin-top: -4px;
      padding: 8px 0 16px 8px;

      .success {
        color: #30cb82;
      }
      .audit {
        color: #3370ff;
      }
      .error {
        color: #ff0000;
      }
    }
  }
}
</style>
